var React = require('react');
var AppView = require('../../common/component/view/app-view.node');
module.exports = function(props) {
  var newFlag = props.crudType === 'new';
  var editFlag = props.crudType === 'edit';
  var viewFlag = props.crudType === 'view';
  return /*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement(AppView, {
    hasNav: true
  }, /*#__PURE__*/ React.createElement("nav", {
    "aria-label": "breadcrumb",
    className: "x-view-nav"
  }, /*#__PURE__*/ React.createElement("ol", {
    className: "breadcrumb"
  }, /*#__PURE__*/ React.createElement("li", {
    className: "breadcrumb-item"
  }, "${t('ui.example.example2Search.title.example2')}"), /*#__PURE__*/ React.createElement("li", {
    className: "breadcrumb-item active",
    "aria-current": "page"
  }, props.viewTitle))), /*#__PURE__*/ React.createElement("div", {
    className: "x-view-title"
  }, props.viewTitle), /*#__PURE__*/ React.createElement("form", null, !newFlag && /*#__PURE__*/ React
    .createElement("div", {
      className: "form-group"
    }, /*#__PURE__*/ React.createElement("label", {
      htmlFor: "id"
    }, "${t('ui.example.example2.field.id')}"), /*#__PURE__*/ React.createElement("input", {
      type: "text",
      className: "form-control",
      id: "id",
      name: "id",
      "data-x-name": "id",
      readOnly: viewFlag || editFlag
    })), /*#__PURE__*/ React.createElement("div", {
      className: "form-group"
    }, /*#__PURE__*/ React.createElement("label", {
      htmlFor: "exampleName"
    }, "${t('ui.example.example2.field.exampleName')}"), /*#__PURE__*/ React.createElement("input", {
      type: "text",
      className: "form-control",
      id: "exampleName",
      name: "exampleName",
      "data-x-name": "exampleName",
      readOnly: viewFlag
    })), /*#__PURE__*/ React.createElement("div", {
      className: "form-group"
    }, /*#__PURE__*/ React.createElement("label", {
      htmlFor: "remark"
    }, "${t('ui.example.example2.field.remark')}"), /*#__PURE__*/ React.createElement("input", {
      type: "text",
      className: "form-control",
      id: "remark",
      name: "remark",
      "data-x-name": "remark",
      readOnly: viewFlag
    })), /*#__PURE__*/ React.createElement("div", {
      className: "form-group"
    }, /*#__PURE__*/ React.createElement("label", {
      htmlFor: "enableFlag"
    }, "${t('ui.example.example2.field.enableFlag')}"), /*#__PURE__*/ React.createElement("select", {
      className: "form-control",
      id: "enableFlag",
      name: "enableFlag",
      "data-x-name": "enableFlag",
      readOnly: viewFlag
    }, /*#__PURE__*/ React.createElement("option", {
      value: "true"
    }, "${t('ui.system.common.option.bool.true')}"), /*#__PURE__*/ React.createElement("option", {
      value: "false"
    }, "${t('ui.system.common.option.bool.false')}"))), !newFlag &&
    /*#__PURE__*/
    /* 版本号 */
    React.createElement("input", {
      type: "hidden",
      "data-x-name": "versionNumber"
    }), /*#__PURE__*/ React.createElement("div", {
      className: "x-footer-bar"
    }, (newFlag || editFlag) && /*#__PURE__*/ React.createElement("button", {
      "data-x-ui": "saveBtn",
      type: "button",
      className: "btn btn-primary"
    }, "${t('ui.example.example2.btn.save')}"), /*#__PURE__*/ React.createElement("button", {
      "data-x-ui": "backBtn",
      type: "button",
      className: "btn btn-primary"
    }, "${t('ui.example.example2.btn.back')}")))));
};